
#include "introducescene.h"
#include"mypushbutton.h"

IntroduceScene::IntroduceScene(QWidget *parent)
    : QMainWindow{parent}
{
    this->setWindowTitle("原神");
    this->setWindowIcon(QIcon("://resource/tubiao.png"));

    MyPushButton* backbtn=new MyPushButton(":/resource/backbtn.png",":/resource/backbtnpressed.png");
    backbtn->setParent(this);
    backbtn->move(920,30);

    connect(backbtn,&QPushButton::clicked,this,[=](){
        emit this->back();
    });
}

void IntroduceScene::paintEvent(QPaintEvent*)
{
    QPainter painter(this);
    QPixmap pix;
    pix.load(":/resource/introducescene.png");
    pix.scaled(1024,648);
    painter.drawPixmap(0,0,1024,648,pix);
}
